<ion-view view-title="添加家属" class="xg-feedback-view xg-percar-publish " ng-controller="addRelativeCtrl">
  <ion-nav-buttons side="left">
    <a class="ion-ios-arrow-back" href="#/my_family"></a>
  </ion-nav-buttons>
  <ion-content class="padding xg-feedback-content xg-percar-publish-content">
    <div class="list">
      <ng-form name="familyForm">
      <label class="item item-input">
        <span class="input-label">姓名：</span>
        <input type="text" placeholder="仅限三代内直系亲属" ng-model="relative.name" ng-minlength="2" ng-maxlength="3" required>
      </label>
      <div class="item item-input item-select">
        <div class="input-label">与本人关系：</div>
        <select  ng-options="relation.name for relation in relations" ng-model="relative.selected" required>

        </select>
      </div>
      <label class="item item-input">
        <span class="input-label">联系方式：</span>
        <input type="text" ng-model="relative.contact" placeholder="选填">
      </label>
      <button class="button button-full xg-feedback-btn xg-family-add-btn" ng-click="insertRelative()" ng-disabled="familyForm.$invalid">
        确定
      </button>
      </ng-form>
    </div>
  </ion-content>
</ion-view>
